#include "mywidget.h"
#include "ui_mywidget.h"
#include "mylineedit.h"
#include <QDebug>
#include <QKeyEvent>
MyWidget::MyWidget(QWidget *parent) :
    QWidget(parent),
    ui(new Ui::MyWidget)
{
    ui->setupUi(this);
    MyLineEdit *lineEdit = new MyLineEdit(this);
    lineEdit->move(100,100);

}

MyWidget::~MyWidget()
{
    delete ui;
}

void MyWidget::keyPressEvent(QKeyEvent *event)
{
    qDebug()<<tr("Widget 键盘按下事件");
}

void MyWidget::on_lineEdit_textChanged(const QString &arg1)
{
    qDebug()<<tr("信号和槽");
}
